﻿using Credera.Theta.Host.WindowsForms;
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
using System.Xml.Serialization;

namespace Credera.Theta.Utility
{
    public partial class frmMain : Form
    {
        private HostInterface _host = null;

        public frmMain()
        {
            InitializeComponent();

            _host = new HostInterface(Host.HostInterfaceMode.Output);
            _host.Dock = DockStyle.Fill;
            this.Controls.Add(_host);
        }

        protected override void OnShown(EventArgs e)
        {
            base.OnShown(e);

            if (_host.Modules.Install(typeof(Credera.Theta.Modules.Environments.Module), _host.Out)) 
            {
                _host.Clear();
                _host.Mode = Host.HostInterfaceMode.Interactive;
            }

        }

    }
}
